package com.iretailer.report.dto.report;


import lombok.Data;

import java.time.LocalDateTime;
import java.time.LocalTime;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * @author Bennie
 * @Auther: xjw
 * @Date: 2019/1/28 14:00
 * @Description:
 */
@Data
public class ReReport {

    // private ReRelation relation;
    private List<String> dataFields;
    private List<ReGroupBy> groupBy;
    private ReLocatoins locations;
    private String startDate;
    private String endDate;
    private LocalTime startTime;
    private LocalTime endTime;
    private LocalDateTime nowTime;


    public Map<String, String> getDataFieldsMap() {
        Map<String, String> fieldMap = new HashMap<>();
        if (this.dataFields != null && this.dataFields.size() > 0) {
            for (String s : dataFields) {
                fieldMap.put(s, s);
            }
        }
        return fieldMap;
    }
}
